/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 苏李涛
 * Date: 2024-05-29
 * Time: 17:42
 */
public class Main {
    public static void main(String[] args) {
        // 使用常量串构造
        String s1 = "haha";

        // 直接newString对象
        String s2 = new String("hehe");

        // 使用字符数组进行构造
        char[] array = {'h', 'o'};
        String s3 = new String(array);
    }

}
